﻿using com.nm.Attributes;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BaseAPI.model
{
   public class DictData
    {
        public class SysDictList : PageDictList
        {
            [ParamDescription("控件类型")]
            public int ControlType { get; set; }
            [ParamDescription("保存的值")]
            public string Value { get; set; }
            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("删除标识")]
            public bool ConfigIsRemove { get; set; }
        }

        /// <summary>
        /// 系统字典
        /// </summary>
        public class PageDictList : SysDictData
        {
            [ParamDescription("字典列表")]
            public IList<PageDictList> Childrens { get; set; }
        }

        public class SysDictData
        {
            [ParamDescription("ID")]
            public int ID { get; set; }

            [ParamDescription("名称")]
            public string DictName { get; set; }

            [ParamDescription("值")]
            public string DictValue { get; set; }

            [ParamDescription("父ID")]
            public int ParentId { get; set; }

            [JsonProperty(NullValueHandling = NullValueHandling.Include)]
            [ParamDescription("删除标识")]
            public bool IsRemove { get; set; }

            [ParamDescription("说明")]
            public string Memo { get; set; }

            [ParamDescription("设置类型标示")]
            public bool SystemIdentifier { get; set; }
        }
    }
}
